﻿using Abp.Domain.Entities;
using System;
using System.ComponentModel.DataAnnotations;

namespace Laboratory.Entities
{
    public class Project : Entity<Guid>
    {

        public string Name { get; private set; }

        public DateTime Time { get; private set; }

        public int ProNum { get; private set; }

        public bool IsEnabled { get; private set; }


        protected Project()
        {

        }

        public Project(string name, int proNum)
        {
            this.Id = Guid.NewGuid();
            this.Name = name;
            this.Time = DateTime.Now;
            this.ProNum = proNum;
            this.IsEnabled = true;
        }


        public void Update(string name, int proNum)
        {
            this.Name = name;
            this.ProNum = proNum;
        }

        public void SetIsEnabled(bool isEnabled)
        {
            this.IsEnabled = isEnabled;
        }

    }
}